package org.example.inventory.util;

import java.sql.Connection;
import java.sql.SQLException;

@FunctionalInterface
public interface TransactionCallback<T> {
    /**
     *
     * @param connection 入参连接对象
     * @return 事务执行结果
     * @throws SQLException 自定义异常
     */
    T execute(Connection connection) throws SQLException;
}
